/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package com.camelspit.preludetoarmageddon.util;
import java.net.*;
import java.io.*;
/**
 *
 * @author DMK
 */
public class UtilLib {

    public static URI getFileLocURI(Object obj, String file){
        URI loc;

        //initialize URL
        URL url = obj.getClass().getResource(file);

        //File does not take URL so convert to URI
        try{
                loc = url.toURI();
        }
        catch(URISyntaxException e) {
            return null;
        }
        return loc;
    }
}
